package com.treasure.mall.biz.repository.pay;

import com.treasure.mall.biz.base.JpaSearchableRepository;
import com.treasure.mall.biz.entity.pay.PaymentBillPO;
import com.treasure.mall.zbq.common.ienum.order.OrderEnums;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author allan
 * @version 1.0.0
 * @date 2020/6/14
 */
@Repository
public interface PaymentRepository extends JpaSearchableRepository<PaymentBillPO, String> {
    List<PaymentBillPO> findByOrderId(String orderId);

    PaymentBillPO findByOrderIdAndThirdPayIsTrue(String orderId);

    List<PaymentBillPO> findByOrderIdAndThirdPayIsFalse(String orderId);

    PaymentBillPO findByOrderIdAndPayType(String orderId, OrderEnums.PayType payType);
}
